export default [
  {
    path: '/',
    redirect: '/merchant',
  },
  {
    name: '商户管理',
    path: '/merchant',
    component: './PageBreadcrumbs',
    icon: 'UserOutlined',
    access: 'merchan_manage_permissions',
    routes: [
      { path: '/merchant', redirect: '/merchant/auditing' },
      {
        path: 'auditing',
        name: '入驻审核',
        icon: 'IssuesCloseOutlined',
        component: './Merchant/Auditing/List/index',
        access: 'merchan_manage_permissions_audit',
      },
      {
        path: 'inventory',
        name: '商户清单',
        icon: 'UnorderedListOutlined',
        component: './Merchant/Inventory/List/index',
        access: 'merchan_manage_permissions_inventory',
      },
      {
        path: 'config',
        name: '商户配置',
        icon: 'PartitionOutlined',
        component: './Merchant/Config/List/index',
        access: 'merchan_manage_permissions_config',
      },

      {
        path: 'auths-dict',
        name: '配置权限码',
        icon: 'PartitionOutlined',
        component: './Merchant/AuthsDict/List/index',
      },
    ],
  },
  {
    name: '换电管理',
    path: '/replacing-battery',
    icon: 'ThunderboltOutlined',
    component: './PageBreadcrumbs',
    access: 'battery_manage_permissions',
    routes: [
      { path: '/replacing-battery', redirect: '/replacing-battery/rule' },
      {
        path: 'rule',
        name: '规则列表',
        icon: 'PushpinOutlined',
        component: './ReplacingBattery/BindRule/List',
        access: 'battery_manage_permissions_rule',
      },
      {
        path: 'coupon',
        name: '优惠券规则',
        icon: 'TagsOutlined',
        component: './ReplacingBattery/CouponRule/List',
        access: 'battery_manage_permissions_coupon_rule',
      },
    ],
  },
  {
    name: '数据管理',
    path: '/user',
    icon: 'PieChartOutlined',
    component: './PageBreadcrumbs',
    access: 'data_manage_permissions',
    routes: [
      { path: '/user', redirect: '/user/developing-users' },
      {
        path: 'developing-users',
        name: '发展用户清单',
        icon: 'TableOutlined',
        component: './User/Develop/List',
        access: 'data_manage_permissions_developing_log',
      },
      {
        path: 'list-of-single-electric-users',
        name: '单电用户清单',
        icon: 'TableOutlined',
        component: './User/Renting/List',
        access: 'data_manage_permissions_single_electric_users',
      },
      {
        path: 'car-electric-user-list',
        name: '车电用户清单',
        icon: 'TableOutlined',
        component: './User/Renting/List',
        access: 'data_manage_permissions_car_electric_user_list',
      },
      {
        path: 'overdue-users',
        name: '逾期用户清单',
        icon: 'TableOutlined',
        component: './User/Overdue/List',
        access: 'data_manage_permissions_overdue',
      },
      {
        path: 'user-upload',
        name: '上传数据',
        icon: 'TableOutlined',
        component: './User/Upload',
        access: 'data_manage_permissions_upload',
      },
    ],
  },
  {
    name: '日志管理',
    path: '/journal',
    icon: 'OrderedListOutlined',
    component: './PageBreadcrumbs',
    access: 'log_manage_permissions',
    routes: [
      { path: '/journal', redirect: '/journal/check' },
      {
        path: 'check',
        name: '校验日志',
        icon: 'FileTextOutlined',
        component: './Journal/Check/List',
        access: 'log_manage_permissions_check',
      },
      {
        path: 'binding',
        name: '绑定日志',
        icon: 'FileTextOutlined',
        component: './Journal/Binding/List',
        access: 'log_manage_permissions_binding',
      },
      {
        path: 'coupon',
        name: '优惠券日志',
        icon: 'FileTextOutlined',
        component: './Journal/Coupon/List',
        access: 'log_manage_permissions_coupon',
      },
      {
        path: 'battery-inquiry',
        name: '电池定位查询日志',
        icon: 'FileTextOutlined',
        component: './Journal/Inquiry/List',
        access: 'log_manage_permissions_battery_inquiry',
      },
      {
        path: 'data-upload',
        name: '数据上传日志',
        component: './Journal/DataUpload/List',
        icon: 'FileTextOutlined',
        access: 'log_manage_permissions_upload',
      },
      {
        path: 'channelLog',
        name: '渠道转个人日志',
        component: './Journal/Journal/List',
        icon: 'FileTextOutlined',
        access: 'log_manage_permissions_channelLog',
      },
      {
        path: 'overdueLog',
        name: '消除逾期日志',
        component: './Journal/Journal/List',
        icon: 'FileTextOutlined',
        access: 'log_manage_permissions_overdueLog',
      },
      {
        path: 'bindingLog',
        name: '绑定电池日志',
        component: './Journal/Journal/List',
        icon: 'FileTextOutlined',
        access: 'log_manage_permissions_bindingLog',
      },
      {
        path: 'unbindLog',
        name: '解绑电池日志',
        component: './Journal/Journal/List',
        icon: 'FileTextOutlined',
        access: 'log_manage_permissions_unbindLog',
      },
      {
        path: 'batterySearch',
        name: '电池查询日志',
        component: './Journal/Journal/List',
        icon: 'FileTextOutlined',
        access: 'log_manage_permissions_unbindLog',
      },
      {
        path: 'openLog',
        name: '电柜开门日志',
        component: './Journal/Journal/List',
        icon: 'FileTextOutlined',
        access: 'log_manage_permissions_unbindLog',
      },
    ],
  },
  {
    name: '财务管理',
    path: '/finance',
    component: './PageBreadcrumbs',
    icon: 'AreaChartOutlined',
    access: 'finance_manage_permissions',
    routes: [
      { path: '/finance', redirect: '/finance/withdrawal' },
      // {
      //   path: 'developinguserrules',
      //   name: '发展用户规则',
      //   icon: 'crown',
      //   component: './Finance/DevelopRule/List',
      // },
      {
        path: 'withdrawal',
        name: '商户提现管理',
        icon: 'crown',
        component: './Finance/Withdrawal/List',
        access: 'withdrawal-manage'
      },
    ],
  },
  {
    name: '系统配置',
    path: '/setting',
    // icon: 'setting',
    component: './PageBreadcrumbs',
    access: 'system_config_permissions',
    routes: [
      { path: '/setting', redirect: '/setting/config' },
      {
        path: 'config',
        name: '系统配置',
        icon: 'crown',
        component: './Setting/index',
        access: 'system_config_permissions_list',
      },
      {
        path: 'notice',
        name: '公告',
        icon: 'crown',
        component: './Setting/Notice/List',
        access: 'system_config_permissions_notice',
      },
      {
        path: 'permissions',
        name: '权限列表',
        icon: 'crown',
        component: './Setting/Permissions/List',
        access: 'system_config_permissions_permissions',
      },
      {
        path: 'user-role',
        name: '角色管理',
        icon: 'crown',
        component: './Setting/UserRole/List',
        access: 'user_role_config_permissions_permissions'
      },
      {
        path: 'user-list',
        name: '用户管理',
        icon: 'crown',
        component: './Setting/User/List',
        access: 'user_list_config_permissions_permissions'
      },
      // 角色权限配置Role permission
      // {
      //   path: 'role-permission-config',
      //   name: '角色权限配置',
      //   icon: 'crown',
      //   component: './Setting/RolePermission/List',
      // },
    ],
  },
  {
    name: '登录',
    path: '/login',
    component: './Login',
    hideInMenu: true,
    layout: false,
  },
];
